package app.biz.service;

import io.seata.rm.tcc.api.BusinessActionContext;
import io.seata.rm.tcc.api.LocalTCC;
import io.seata.rm.tcc.api.TwoPhaseBusinessAction;

/**
 * The interface Tcc action two.
 *
 * @author zhangsen
 */
@LocalTCC
public interface TccActionThree {

    /**
     * Prepare boolean.
     *
     * @param actionContext the action context
     * @return the boolean
     */
    @TwoPhaseBusinessAction(
            name = "TccActionThree",
            commitMethod = "commit",
            rollbackMethod = "rollback")
     boolean prepare(BusinessActionContext actionContext);

    /**
     * Commit boolean.
     *
     * @param actionContext the action context
     * @return the boolean
     */
     boolean commit(BusinessActionContext actionContext);

    /**
     * Rollback boolean.
     *
     * @param actionContext the action context
     * @return the boolean
     */
     boolean rollback(BusinessActionContext actionContext);

}
